package lesson18;

public class Zoo {

	Mammal[] mammals = new Mammal[2];
	
	public void makeAllAnimalsNoisy()
	{
		for (int i= 0 ; i < mammals.length; i++)
		{
			System.out.println("======");
			mammals[i].makeNoise();
			mammals[i].move("forward");
		}
			
	}
	
	
	public void allAnimalsGiveBirth()
	{
		for (int i= 0 ; i < mammals.length; i++)
		{
			System.out.println("======");
			mammals[i].giveBirth(2);
		}
			
	}
	
	public void allAnimalsWalk()
	{
		for (int i= 0 ; i < mammals.length; i++)
		{
			System.out.println("======");
			mammals[i].walk();
		}
			
	}
	
	public void allAnimalsStayStill()
	{
		for (int i= 0 ; i < mammals.length; i++)
		{
			System.out.println("======");
			mammals[i].stayStill();;
		}
			
	}
	
}
